<template>
  <view class="webview-page">
    <web-view :src="src"></web-view>
  </view>
</template>

<script>
export default {
  data() {
    return {
      src: 'https://m.baidu.com'
    }
  },
  onLoad(options) {
    // this.src = options.url
    console.log('webview onload')
  },
  onBackPress(options) {
		console.log('from:' + options.from)
    return false
	}
}
</script>

<style lang="less" scoped>
.webview-page{
  position: relative;
  height: calc(100vh - var(--window-top) - var(--status-bar-height));
}
</style>